import Vue from 'vue'
import App from './App.vue'
//引入ElementUI组件库
import ElementUI from 'element-ui';
//引入ElementUI全部样式
import 'element-ui/lib/theme-chalk/index.css';
//引入store文件
import store from "./vuex/store.js"
//引入VueRouter插件
import VueRouter from 'vue-router'
//引入自定义的src/touter/index.js
import router from './router/index.js'
import axios from 'axios'
import http from '@/api/config'
//mavonEditor
// import mavonEditor from 'mavon-editor'
// import 'mavon-editor/dist/css/index.css'
// // use
// Vue.use(mavonEditor)
//全局注册基于Vue的markdown编辑器mavon-editor
import marked from 'marked'
//引入时间转化 工具
import moment from 'moment'
 Vue.prototype.$moment  =  moment; 
// Vue.filter('dateFormat',(dateStr,pattern='YYYY-DD-MM HH:mm:ss')=>{
// 	return moment(dateStr).format(pattern);
// })



Vue.config.productionTip = false
// 将axios挂载到Vue上
Vue.prototype.$axios = axios

//引入websocket工具类
import websocket  from '@/utils/WebSocket.js'
//挂载websocket工具类
Vue.prototype.$websocket = websocket




//使用ElementUI
Vue.use(ElementUI)
//使用路由
Vue.use(VueRouter)
//使用自定义的axios
Vue.use(http)
new Vue({
	render: h => h(App),
	store, //注册vuex
	router, //注册自定义的路由
}).$mount('#app')
